Skip to content

Allow Staff members to message groups #5922

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 16 commits into from
Apr 11, 2024

Conversation

smithellis
Copy link
Contributor

@smithellis smithellis commented Mar 18, 2024

  • API for messages to get users/groups
  • Added custom form field type in form_fields.py to handle group AND user selection and validation
  • Update form, models, urls and tests for messages
  • Update group profile page to add button for messaging group
  • Removed unnecessary validation from view.py for new_messages
  • Rewrote new_messages to handle Groups
  • New .js file for handling drop down for messages messages.autocomplete.js
  • Updated webpack entrypoints.js to handle new file
  • Updated tokenizer.js
  • Updated outbox.html, read-outbox.html and _inbox.scss
  • Created abstracted group in settings.py for our Staff group
  • Added new cached property to Profile model for in_staff_group
  • Added in_staff_group function to sumo/utils.py ( thanks @escattone ! )

@smithellis smithellis changed the title Allow Staff memebers to message groups Allow Staff members to message groups Mar 18, 2024
@smithellis smithellis force-pushed the v2-allow-pm-to-groups branch from c874653 to 44283fb Compare March 19, 2024 14:28
@smithellis smithellis force-pushed the v2-allow-pm-to-groups branch 4 times, most recently from 3c747c5 to 361f1cf Compare March 21, 2024 19:56
@smithellis smithellis marked this pull request as ready for review March 21, 2024 19:59
@smithellis smithellis requested a review from akatsoulas March 21, 2024 20:19
@smithellis smithellis force-pushed the v2-allow-pm-to-groups branch from 361f1cf to 8af5103 Compare March 22, 2024 18:22
@smithellis smithellis force-pushed the v2-allow-pm-to-groups branch 2 times, most recently from b65a6b7 to d894db5 Compare March 31, 2024 18:34
* api for messages
* Update form, models, urls and tests
* New .js file for users_or_groups handling
* Updated tokenizer.js
* Tweaks to outbox and message reading templates
* icons for user, group selection dropdown
* Since validation is handled in `form_fields.py` for the to
  input we don't need to check again in `views.py`
Ensure errors appear on form when a To value fails validation
@smithellis smithellis force-pushed the v2-allow-pm-to-groups branch from 9a2cef1 to e9646fa Compare April 9, 2024 15:41
Copy link
Contributor

@escattone escattone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@smithellis With this latest realization, I've changed my mind and no longer like the idea of putting is_staff (or whatever we rename it to) on the profile. I'd vote for using the function approach instead.

@smithellis smithellis force-pushed the v2-allow-pm-to-groups branch from 15539a6 to 5d0562f Compare April 10, 2024 21:04
Copy link
Contributor

@escattone escattone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r+wc

Just a typo change.

@smithellis smithellis merged commit 7cdffd7 into mozilla:main Apr 11, 2024
@smithellis smithellis deleted the v2-allow-pm-to-groups branch April 11, 2024 14:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants